package com.example.entity.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.time.LocalDateTime;
import java.util.List;

/**
 * Created with IntelliJ IDEA.
 *
 * @Author: tjatse
 * @Date: 2025/05/07/22:11
 * @Description:
 */

@Data
public class ClassifyVo {

    @Schema(description = "分类id")
    private Integer id;

    @Schema(description = "分类名称")
    private String name;

    @Schema(description = "分类描述")
    private String description;

    @Schema(description = "父级分类id")
    private Integer parentId;

    @Schema(description = "父级分类名称")
    private String parentName;

    @Schema(description = "层级")
    private Integer level;

    @Schema(description = "创建人")
    private String createdBy;

    @Schema(description = "更新人")
    private String updatedBy;

    @Schema(description = "创建时间")
    private LocalDateTime createdTime;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",  timezone = "GMT+8")
    @Schema(description = "更新时间")
    private LocalDateTime updatedTime;

    @Schema(description = "子分类")
    private List<ClassifyVo> children;
}
